﻿@model LoginViewModel
@using NewLife.Common;
@{
    Layout = null;
    ViewBag.Title = "登录";

    var res = Model.ResourceUrl;
}
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->

    <title>@ViewBag.Title - @SysConfig.Current.DisplayName</title>
    <link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" />

    <!-- 基本样式 -->
    <link href="@res/bootstrap/css/bootstrap.min.css" rel="stylesheet" />
    <!-- 自定义样式-->
    <link href="@res/Cube.css" rel="stylesheet" />
    <!-- 仅用于过渡期兼容-->
    <style>
        .login-logo {
            width: 130px;
            font-size: 130px;
            color: #4CA6FF;
            margin-top: 50px;
        }

        .cube-login {
            background: #fff;
            padding-bottom: 0;
            border-radius: 15px;
            text-align: center;
        }

            .cube-login .heading {
                display: block;
                font-size: 24px;
                font-weight: 700;
                padding: 5px 0;
                margin-bottom: 20px;
            }

            .cube-login .form-group {
                padding: 0 40px;
                margin: 0 0 25px 0;
                position: relative;
                display: block;
            }

                .cube-login .form-group.clear-fix {
                    overflow: hidden;
                    clear: both;
                }

            .cube-login .form-control {
                border-radius: 20px;
                box-shadow: none;
                padding: 0 20px 0 45px;
                height: 40px;
                transition: all 0.3s ease 0s;
            }

                .cube-login .form-control:focus {
                    background: #e0e0e0;
                    box-shadow: none;
                    outline: 0 none;
                }

            .cube-login .form-group i {
                position: absolute;
                top: 12px;
                left: 60px;
                font-size: 17px;
                color: #c8c8c8;
                transition: all 0.5s ease 0s;
            }

            .cube-login .form-group a {
                position: absolute;
                top: 12px;
                right: 0px;
                font-size: 17px;
                color: #c8c8c8;
                transition: all 0.5s ease 0s;
                color: #4CA6FF;
            }

            .cube-login .form-control:focus + i {
                color: #00b4ef;
            }

            .cube-login .fa-question-circle {
                display: inline-block;
                position: absolute;
                top: 12px;
                right: 60px;
                font-size: 20px;
                color: #808080;
                transition: all 0.5s ease 0s;
            }

                .cube-login .fa-question-circle:hover {
                    color: #000;
                }

            .cube-login .main-checkbox {
                float: left;
                width: 20px;
                height: 20px;
                background: #11a3fc;
                border-radius: 50%;
                position: relative;
                margin: 5px 0 0 5px;
                border: 1px solid #11a3fc;
            }

                .cube-login .main-checkbox label {
                    width: 20px;
                    height: 20px;
                    position: absolute;
                    top: 0;
                    left: 0;
                    cursor: pointer;
                }

                    .cube-login .main-checkbox label:after {
                        content: "";
                        width: 10px;
                        height: 5px;
                        position: absolute;
                        top: 5px;
                        left: 4px;
                        border: 3px solid #fff;
                        border-top: none;
                        border-right: none;
                        background: transparent;
                        opacity: 0;
                        -webkit-transform: rotate(-45deg);
                        transform: rotate(-45deg);
                    }

                .cube-login .main-checkbox input[type=checkbox] {
                    visibility: hidden;
                }

                    .cube-login .main-checkbox input[type=checkbox]:checked + label:after {
                        opacity: 1;
                    }

            .cube-login .text {
                float: left;
                margin-left: 7px;
                line-height: 20px;
                padding-top: 5px;
                text-transform: capitalize;
            }

            .cube-login .btn {
                float: right;
                font-size: 14px;
                color: #fff;
                background: #00b4ef;
                border-radius: 30px;
                padding: 8px 50px;
                border: none;
                text-transform: capitalize;
                transition: all 0.5s ease 0s;
            }

        .ui.divider {
            margin: 1rem 0rem;
            line-height: 1;
            height: 0em;
            font-weight: bold;
            text-transform: uppercase;
            letter-spacing: 0.05em;
            color: rgba(0, 0, 0, 0.85);
            -webkit-user-select: none;
            -moz-user-select: none;
            -ms-user-select: none;
            user-select: none;
            -webkit-tap-highlight-color: rgba(0, 0, 0, 0)
        }

        .ui.horizontal.divider {
            display: table;
            white-space: nowrap;
            height: auto;
            line-height: 1;
            text-align: center
        }

            .ui.horizontal.divider:before,
            .ui.horizontal.divider:after {
                content: '';
                display: table-cell;
                position: relative;
                top: 50%;
                width: 50%;
                background-repeat: no-repeat
            }

            .ui.horizontal.divider:before {
                background-position: right 1em top 50%;
            }

            .ui.horizontal.divider:after {
                background-position: left 1em top 50%
            }

        .ui.divider > .icon {
            margin: 0rem;
            font-size: 1rem;
            height: 1em;
            vertical-align: middle
        }

        .ui.divider {
            font-size: 1rem
        }

        .ui.horizontal.divider:before,
        .ui.horizontal.divider:after {
            background-image: url("");
        }
    </style>
</head>
<body>
    <!--布局容器-->
    <div class="container">
        <div class="row">
            <div class="col-md-6 col-md-offset-3">
                <div class="tab-content">
                    @*<partial name="_Login_Login"/>*@
                    @await Html.PartialAsync("_Login_Login", Model)@*登录页*@
                    @await Html.PartialAsync("_Login_Forgot", Model)@*找回密码页*@
                    @await Html.PartialAsync("_Login_Register", Model)@*注册页*@
                    @await Html.PartialAsync("_Login_Login3", Model)@*第三方登录*@
                </div>
            </div>
        </div>
    </div>
    <!-- JQuery作为一等公民，页面内部随时可能使用 -->
    <script src="@res/js/jquery-3.6.0.min.js"></script>
    <script src="@res/bootstrap/js/bootstrap.min.js"></script>
    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://cdn.bootcss.com/html5shiv/3.7.3/html5shiv.min.js"></script>
      <script src="https://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
    <script src="@res/js/md5.js"></script>

    <script type="text/javascript">
        function md5_plain(p) {
            var pass = p.val();
            if (pass) {
                pass = md5(pass);
                p.val(pass);
            }
        }

        function md5_salt(p) {
            var pass = p.val();
            if (pass) {
                pass = md5(pass);
                var salt = randomString(32);
                //var salt = new Date().getTime() + '';
                pass = md5(pass + salt) + ':' + salt;
                p.val(pass);
            }
        }

        function randomString(length) {
            var x = "0123456789qwertyuioplkjhgfdsazxcvbnm";
            var str = "";
            for (var i = 0; i < length; i++) {
                str += x.charAt(Math.ceil(Math.random() * 100000000) % x.length);
            }
            return str;
        }
    </script>

</body>
@await Html.PartialAsync("_Footer")
</html>